package com.zhuiyun.project.api.plan.fitnessSeries.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zhuiyun.project.api.plan.fitnessPlan.entity.FitnessPlan;
import com.zhuiyun.project.api.plan.fitnessPlan.model.FitnessPlanModel;
import com.zhuiyun.project.api.plan.fitnessSeries.entity.FitnessPurpose;
import com.zhuiyun.project.api.plan.fitnessSeries.entity.FitnessSeries;
import com.zhuiyun.project.api.plan.fitnessSeries.model.FitnessPurposeModel;
import com.zhuiyun.project.api.plan.fitnessSeries.model.FitnessSeriesModel;
import com.zhuiyun.project.common.response.CommonResult;
import com.zhuiyun.project.utils.pageUtil.PageRequest;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface FitnessSeriesMapper extends BaseMapper<FitnessSeries> {
    /**
    * @Author 杨珅
    * @Description todo 健身系列分页查询
    * @Date 2023/11/13 9:01
    * @Return  * @param null
    */
    public List<FitnessSeriesModel> selectAll(PageRequest pageRequest, String seriesName, String venueUniqueIdentifier);
    /**
     * @Author 杨珅
     * @Description todo 健身系列分页查询
     * @Date 2023/11/13 9:01
     * @Return  * @param null
     */
    public List<FitnessSeriesModel> selectCoachAll(PageRequest pageRequest, String seriesName, String venueUniqueIdentifier,Integer coachId);
    /**
     * @Author 杨珅
     * @Description todo 健身系列分页查询
     * @Date 2023/11/13 9:01
     * @Return  * @param null
     */
    public List<FitnessSeriesModel> selectCoachAllS(String seriesName, String venueUniqueIdentifier,Integer coachId);
//    /**
//     * @Author 杨珅
//     * @Description todo 根据用户id查询计划
//     * @Date 2023/11/13 9:01
//     * @Return  * @param null
//     */
//    public List<FitnessPlanModel> selectPlanById(Integer memberId);
    /**
     * @Author 杨珅
     * @Description todo 健身系列新增
     * @Date 2023/11/13 9:01
     * @Return  * @param null
     */
    public int insertFitnessSeries(FitnessSeriesModel fitnessSeriesModel);
//    /**
//     * @Author 杨珅
//     * @Description todo 健身系列修改
//     * @Date 2023/11/13 9:01
//     * @Return  * @param null
//     */
//    public int updateFitnessPlan(FitnessPlan fitnessPlan);
    /**
     * @Author 杨珅
     * @Description todo 健身系列逻辑删除
     * @Date 2023/11/13 9:01
     * @Return  * @param null
     */
    public int deleteFitnessSeries(FitnessSeries fitnessSeries);

    /**
    * @Author 田 
    * @Description 查询健身系列训练部位
    * @Date 2024/3/13 16:34
    * @Return java.util.List<com.zhuiyun.project.api.plan.fitnessSeries.model.FitnessPurposeModel>
    * @param fitnessPurpose
    */
    public List<FitnessPurposeModel> selectPurpose(FitnessPurpose fitnessPurpose);

    /**
    * @Author fei
    * @Description 添加健身系列目的和动作
    * @Date 2024/3/14 10:52
    * @Return int
    * @param fitnessPurposeModel
    */
    @Insert(
            "insert into fitness_series_purpose (" +
                    "fitness_series_id,fitness_purpose_id,fitness_action_id" +
                    ")values(" +
                    "#{id},#{pid},#{fitnessActionId}" +
                    ")"
    )
    public int insertPurPoseAction(FitnessPurposeModel fitnessPurposeModel);

}
